import com.java.component.BeanComponent;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class App {
    public static void main(String[] args) {
        ClassPathXmlApplicationContext classPathXmlApplicationContext =
                new ClassPathXmlApplicationContext("spring-config.xml");
        BeanComponent beanComponent =
                classPathXmlApplicationContext.getBean("beanComponent", BeanComponent.class);
        beanComponent.sayHi();
//        beanComponent.close();
        classPathXmlApplicationContext.close();


    }
}
